#include "main.h"
#include "stdio.h"

void main() {
  SLNode *head;
  int i , x;
  ListInitiate(&head);
  for(i = 0; i < 10; i++) {
    if(ListInsert(head, i, i+1) != 0)
      {
        printf("mistake \n");
        return;
      }
  }

  if(ListDelete(head, 4, &x) == 0) {
    printf("mistake \n");
    return;
  }
  printf("listlength:%d\n", ListLength(head));

  for(i = 0; i < ListLength(head); i++) {
    if(ListGet(head, i, &x) == 0)
      {
        printf("mistake \n");
        return;
      }
    else printf("%d ", x);
  }

  Destroy(&head);
}